package com.vader.admin.entity.DO;

import cn.hutool.core.bean.BeanUtil;
import com.vader.admin.entity.Query.EditIntegrationQuery;

import java.util.Date;
import java.io.Serializable;

/**
 * 用户积分明细表
 * (BaseIntegrationRecord)实体类
 *
 * @author Vader
 * @since 2021-10-06 12:46:39
 */
public class BaseIntegrationRecord implements Serializable {
    private static final long serialVersionUID = 276770279601827380L;
    /**
     * 积分记录id
     */
    private Long id;
    /**
     * 积分类型 0:术值 1:正常龙珠碎片 2:可赠送龙珠碎片 3:龙珠
     */
    private Integer integraionType;
    /**
     * 变化数量
     */
    private Integer sum;
    /**
     * 发送人id
     */
    private Long sendUid;
    /**
     * 接受人id
     */
    private Long receiveUid;
    /**
     * 积分相关事件id
     */
    private Long taskId;

    private Date createTime;

    private Date updateTime;

    public static BaseIntegrationRecord from(EditIntegrationQuery editIntegrationQuery) {
        BaseIntegrationRecord baseIntegrationRecord = new BaseIntegrationRecord();
        BeanUtil.copyProperties(editIntegrationQuery, baseIntegrationRecord);
        return baseIntegrationRecord;
    }


    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Integer getIntegraionType() {
        return integraionType;
    }

    public void setIntegraionType(Integer integraionType) {
        this.integraionType = integraionType;
    }

    public Integer getSum() {
        return sum;
    }

    public void setSum(Integer sum) {
        this.sum = sum;
    }

    public Long getSendUid() {
        return sendUid;
    }

    public void setSendUid(Long sendUid) {
        this.sendUid = sendUid;
    }

    public Long getReceiveUid() {
        return receiveUid;
    }

    public void setReceiveUid(Long receiveUid) {
        this.receiveUid = receiveUid;
    }

    public Long getTaskId() {
        return taskId;
    }

    public void setTaskId(Long taskId) {
        this.taskId = taskId;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

}

